<script setup>
import { storeToRefs } from 'pinia'
import { useCounterStore } from '@/stores/pinia/modules/counter'

const counterStore = useCounterStore()

const { count, double } = storeToRefs(counterStore)

const countAdd = () => {
  counterStore.increment()
}

</script>

<template>
  <button @click="countAdd">{{ count }}</button>
  <p>doubleCount: {{ double }}</p>
</template>

<style scoped></style>
